﻿using System;
using System.Collections.Generic;
using System.Linq;


namespace BHXH.LinqRepository
{
    public interface IRepository<T> where T : class
    {
        T Get(int id);
        List<T> GetAll();
        void Add(T entity);
        void DeleteOnSubmit(T entity);
        void DeleteOnSubmit(T entity, bool logicalDelete);
        void DeleteAllOnSubmit(IEnumerable<T> entities);
        void DeleteAllOnSubmit(IEnumerable<T> entities, bool logicalDelete);
        void SubmitChanges();
        void Delete(int id);

        List<T> GetAll(int start, int limit, out int count);
    } 
}